﻿<Window x:Class="ApplicationDemo.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="Semantic Logging using Reactive Extensions" Height="350" Width="525">
    <Window.Resources>
        <Style x:Key="LinkButtonStyle" TargetType="{x:Type Button}">
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type Button}">
                        <TextBlock TextDecorations="Underline">
                        <ContentPresenter />
                        </TextBlock>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
            <Setter Property="HorizontalContentAlignment" Value="Center"/>
            <Setter Property="VerticalContentAlignment" Value="Center"/>
            <Setter Property="Foreground" Value="Blue" />
            <Setter Property="Cursor" Value="Hand" />
            <Style.Triggers>
                <Trigger Property="IsMouseOver" Value="true">
                    <Setter Property="Foreground" Value="Red" />
                </Trigger>
            </Style.Triggers>
        </Style>
    </Window.Resources>
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition />
            <RowDefinition />
            <RowDefinition />
            <RowDefinition Height="40" />
        </Grid.RowDefinitions>
        <Button Grid.Row="0" Content="Log Informational" Click="InformationalClick" Margin="10"/>
        <Button Grid.Row="1" Content="Log Warning" Click="WarningClick" Margin="10"/>
        <Button Grid.Row="2" Content="Log Error" Click="ErrorClick" Margin="10"/>
        <Button Grid.Row="3" Content="Open log file" Click="OpenLogFile" Margin="10" Style="{StaticResource LinkButtonStyle}" />
    </Grid>
</Window>
